{% extends "global/Page.html" %}
{% load otree %}

{% block title %}
    Results
{% endblock %}

{% block content %}

    <p>
        {% if player.is_winner %}
            You won the auction!
            {% if is_greedy %}
                However, your bid amount was higher than the actual value of the item. Your payoff is therefore zero.
            {% elif player.payoff == 0 %}
                Your payoff, however, is zero.
            {% endif %}
        {% else %}
            You did not win the auction.
        {% endif %}
    </p>

    <table class="table" style="width:400px">

        <tr>
            <th>Your bid</th>
            <th>Winning bid</th>
            <th>Actual value</th>
            <th>Your payoff</th>
        </tr>

    <tr>
        <td>{{ player.bid_amount }}</td>
        <td>{{ group.highest_bid }}</td>
        <td>{{ group.item_value }}</td>
        <td>{{ player.payoff }}</td>
    </tr>

    </table>

    {% next_button %}

{% endblock %}
